n = int(input("待校验数:"))
t = 0
s = ""
while n > 0:
    a = n % 2
    n = n // 2
    t = t+a
    s = str(a)+s
print("二进制值:"+s)
v = t % 2
print("校验位值:"+str(1-v))


